import React from 'react';
import { Table, Card } from 'antd';
import Utils from '@/components/Engineering/utils';

export default class Localfees extends React.Component {
  state = {};
  page = {};
  columns1 = [
    { title: '费用名称(代码)', dataIndex: 'incidenttalName', key: 'incidenttalName' },
    { title: '单位', dataIndex: 'theunit', key: 'theunit' },
    { title: '单票价格', dataIndex: 'unitprice', key: 'unitprice' },
    { title: '币种', dataIndex: 'currency', key: 'currency' },
  ];

  columns2 = [
    { title: '费用名称(代码)', dataIndex: 'incidenttalName', key: 'incidenttalName' },
    { title: '单位', dataIndex: 'theunit', key: 'theunit' },
    { title: '单票价格', dataIndex: 'unitprice', key: 'unitprice' },
    { title: '币种', dataIndex: 'currency', key: 'currency' },
  ];

  render() {
    const { airtrQuotations } = this.props;
    return (
      <Card style={{ marginBottom: 10 }}>
        <h4>杂费</h4>
        <Table
          style={{ marginBottom: 10 }}
          columns={this.columns1}
          dataSource={airtrQuotations.hdInCidentalsList || []}
          pagination={airtrQuotations.hdInCidentalsList.page ? true : false}
          size="small"
        />

        <h4 style={{ marginTop: 20 }}>UDU杂费</h4>
        <Table
          columns={this.columns2}
          dataSource={airtrQuotations.dduddpList || []}
          size="small"
          pagination={airtrQuotations.dduddpList.page ? true : false}
        />
      </Card>
    );
  }
}
